<?php
use App\Model\Comcheck;?>

		<!DOCTYPE html>
<html lang="zh">
<head>
	<meta charset="UTF-8" />
	<meta name="viewport" content="width=device-width, initial-scale=1.0" />
	<meta http-equiv="X-UA-Compatible" content="ie=edge" />
	<title>项目检查统计</title>
	<link rel="stylesheet" href="/css/style.css">
	<style>
		.tyaw li span{
			height: auto;width: auto;
		}
	</style>
</head>
<body style="background: #F2F2F2;">
<p class="yuausj">该项目共检查{{$count}}家企业</p>
<!--<div class="tyaw">-->
<ul class="tyaw">
	<li class="daoh"><span>序号</span><span>隐患统计</span><span>排查地点</span><span>排查人</span></li>
	<?php $i=1;?>
	@foreach ($list as $u)
		<li>
			<?php $chucha = 0;$fucha = 0;?>
			<span>{{$i}}</span>
			@foreach ($comcheckdetail as $v)
				@if($v->checkId == $u->id)
					<?php $chucha ++;?>
				@endif
			@endforeach
			@foreach ($comcheckagain as $v)
				@foreach ($comcheckagaindetail as $v1)
					@if($v->checkId == $u->id && $v->id == $v1->checkId)
						<?php $fucha ++;?>
					@endif
				@endforeach
			@endforeach
			<span><?php echo str_replace('有限公司', '', $u->company->comName);?>初查时共有{{$chucha}}条隐患,复查时已整改{{$fucha}}条 </span>
			<span>
				@foreach ($area as $a){!! $u->company->district == $a->id ? $a->name: '' !!}{!! $u->company->street == $a->id ? $a->name: '' !!}
				@endforeach{{$u->company->address}}</span>
				<span style="width: 10%">{{$u->users->name}} </span>
		</li>
		<?php $i++; ?>
	@endforeach
</ul>
<!--</div>-->
<a class="jcjs dibuann" href="/ninesmall/export?project={{$_GET['project']}}">导出统计表</a>
</body>
</html>